package impl.sdi.business.classes;

import com.sdi.business.exception.EntityNotFoundException;
import com.sdi.infrastructure.Factories;
import com.sdi.model.User;
import com.sdi.persistence.UserDao;
import com.sdi.persistence.exception.NotPersistedException;

public class UsersUpdate {

	public void update(User alumno) throws EntityNotFoundException {
		UserDao dao = Factories.persistence.createUserDao();
		try {
			dao.update(alumno);
		}
		catch (NotPersistedException ex) {
			throw new EntityNotFoundException("Alumno no eliminado " + alumno, ex);
		}
	}

}
